-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add the clusterupgrade feature config for the fleet Feature resource. #9614
Add the clusterupgrade feature config for the fleet Feature resource. #9614
Conversation
Hello! I am a robot. It looks like you are a: Community Contributor @shuyama1, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look. You can help make sure that review is quick by doing a self-review and by running impacted tests locally. |
@kapreus Thanks for working on this feature. Would you mind following the Terraform internal contribution page to get your GitHub account registered, so the tests will be automatically triggered for your PRs. Thanks! |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 3 files changed, 542 insertions(+)) |
Tests analyticsTotal tests:
|
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 3 files changed, 542 insertions(+)) |
Tests analyticsTotal tests:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM overall. Only some small comments
mmv1/products/gkehub2/Feature.yaml
Outdated
- !ruby/object:Api::Type::String | ||
name: 'name' | ||
description: | | ||
Name of the upgrade, e.g., "k8s_control_plane". It should be a valid upgrade name. It must not exceet 99 characters. | ||
- !ruby/object:Api::Type::String | ||
name: 'version' | ||
description: | | ||
Version of the upgrade, e.g., "1.22.1-gke.100". It should be a valid version. It must not exceet 99 characters. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we make at least one of these subfields required to prevent users from sending empty blocks?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done, made both of the fields required
location = "global" | ||
spec { | ||
clusterupgrade { | ||
upstream_fleets = [tostring(google_project.project_2.number)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
upstream_fleets = [tostring(google_project.project_2.number)] | |
upstream_fleets = [google_project.project_2.number] |
I'd assume it should be working without tostring
since number
should be type of string: https://github.com/hashicorp/terraform-provider-google-beta/blob/main/google-beta/services/resourcemanager/resource_google_project.go#L102
Plus, just want to make sure if it will return the values in the order as they send for multiple entries. Otherwise, we'll need to implement it as set.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
The order doesn't change; also, right now having more than upstreams is not supported
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 3 files changed, 542 insertions(+)) |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 3 files changed, 543 insertions(+)) |
Tests analyticsTotal tests:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall LGTM! only one small nit-pick
ImportStateVerify: true, | ||
ImportStateVerifyIgnore: []string{"update_time"}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ImportStateVerify: true, | |
ImportStateVerifyIgnore: []string{"update_time"}, | |
ImportStateVerify: true, | |
ImportStateVerifyIgnore: []string{"update_time"}, |
nit: tabs for indentation here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed!
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 3 files changed, 543 insertions(+)) |
48aecb1
to
e24bbaa
Compare
Tests analyticsTotal tests: Click here to see the affected service packages
|
Tests analyticsTotal tests: Click here to see the affected service packages
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
…GoogleCloudPlatform#9614) * Add support for gkehub clusterupgrade feature * Fix gkehub Feature indentation * Remove unnecessary tostring() call * Make upgrade type and version fields required for specifying overrides * Ignore update_time in tests * Replace tabulations with spaces
…GoogleCloudPlatform#9614) * Add support for gkehub clusterupgrade feature * Fix gkehub Feature indentation * Remove unnecessary tostring() call * Make upgrade type and version fields required for specifying overrides * Ignore update_time in tests * Replace tabulations with spaces
…GoogleCloudPlatform#9614) * Add support for gkehub clusterupgrade feature * Fix gkehub Feature indentation * Remove unnecessary tostring() call * Make upgrade type and version fields required for specifying overrides * Ignore update_time in tests * Replace tabulations with spaces
…GoogleCloudPlatform#9614) * Add support for gkehub clusterupgrade feature * Fix gkehub Feature indentation * Remove unnecessary tostring() call * Make upgrade type and version fields required for specifying overrides * Ignore update_time in tests * Replace tabulations with spaces
Add the clusterupgrade feature config for the fleet Feature resource. Fixes hashicorp/terraform-provider-google#16459
Release Note Template for Downstream PRs (will be copied)